#include <stdio.h>

int main(){
    FILE* f = fopen("a.v", "w");
    for(int i = 0; i < 64; i++){
        for(int j = 0; j < 64; j++){
            int x1 = (i >> 3), y1 = (j >> 3);
            int x2 = (i & 7), y2 = (j & 7);
            fprintf(f, "$fwrite(img_file, \"%%c%%c%%c\"");
            fprintf(f, ", sche.block_inst.frame.frame[%d][%d][%d][%d][7:0]", x1, y1, x2, y2);
            fprintf(f, ", sche.block_inst.frame.frame[%d][%d][%d][%d][15:8]", x1, y1, x2, y2);
            fprintf(f, ", sche.block_inst.frame.frame[%d][%d][%d][%d][23:16]", x1, y1, x2, y2);
            fprintf(f, ");\n");
        }
    }
    fclose(f);
}